from GuiObject import *

class GuiTxt(GuiObject):
	def __init__(self, x_, y_, text_, font_, fontSize_, color_):
		GuiObject.__init__(self)
		self.text = text_
		self.font = pygame.font.Font(font_, fontSize_)
		textWH = self.font.size(self.text)
		self.x = x_
		self.y = y_
		self.w = textWH[0]
		self.h = textWH[1]
		self.color = color_
	def draw(self):
		textSurface = self.font.render(self.text, 1, self.color)
		self.screen.blit(textSurface, ( self.getX(), self.getY(), self.w, self.h))
